package com.sz.youban.dt.entity.terminal;

import java.io.Serializable;
import java.util.Date;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;

/**
 * <p>
 * 通话记录信息
 * </p>
 *
 * @author liyang
 * @since 2017-06-05
 */
@TableName("dt_call_records")
public class DtCallRecords extends Model<DtCallRecords> {

    private static final long serialVersionUID = 1L;
	@TableId(value="id", type= IdType.AUTO)
	
	private Integer id;
    /**
     * 登录的用户id
     */
	@TableField("user_id")
	private Integer userId;
	/**
	 * app登录用户手机号
	 */
	@TableField("app_phone")
	private String appPhone;
    /**
     * 联系人手机号
     */
	private String phone;
    /**
     * 通话开始时间
     */
	@TableField("start_time")
	private Date startTime;
    /**
     * 通话持续时间
     */
	@TableField("sustain_time")
	private Long sustainTime;
    /**
     * 1:呼入,2:呼出
     */
	@TableField("call_flag")
	private Integer callFlag;
    /**
     * 时间戳
     */
	private Date tsp;


	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Integer getUserId() {
		return userId;
	}

	public void setUserId(Integer userId) {
		this.userId = userId;
	}

	public String getAppPhone() {
		return appPhone;
	}

	public void setAppPhone(String appPhone) {
		this.appPhone = appPhone;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public Date getStartTime() {
		return startTime;
	}

	public void setStartTime(Date startTime) {
		this.startTime = startTime;
	}

	public Long getSustainTime() {
		return sustainTime;
	}

	public void setSustainTime(Long sustainTime) {
		this.sustainTime = sustainTime;
	}

	public Integer getCallFlag() {
		return callFlag;
	}

	public void setCallFlag(Integer callFlag) {
		this.callFlag = callFlag;
	}

	public Date getTsp() {
		return tsp;
	}

	public void setTsp(Date tsp) {
		this.tsp = tsp;
	}

	@Override
	protected Serializable pkVal() {
		return this.id;
	}

	@Override
	public String toString() {
		return "DtCallRecords{" +
				"id=" + id +
				", userId=" + userId +
				", appPhone='" + appPhone + '\'' +
				", phone='" + phone + '\'' +
				", startTime=" + startTime +
				", sustainTime=" + sustainTime +
				", callFlag=" + callFlag +
				", tsp=" + tsp +
				'}';
	}
}
